/*
 * Copyright the original author or authors.
 * 
 * Licensed under the MOZILLA PUBLIC LICENSE, Version 1.1 (the "License");
 * you may not use this file except in compliance with the License.
 * You may obtain a copy of the License at
 * 
 *      http://www.mozilla.org/MPL/MPL-1.1.html
 * 
 * Unless required by applicable law or agreed to in writing, software
 * distributed under the License is distributed on an "AS IS" BASIS,
 * WITHOUT WARRANTIES OR CONDITIONS OF ANY KIND, either express or implied.
 * See the License for the specific language governing permissions and
 * limitations under the License.
 */
 package com.blitscreen.gesture
{
	/**
	 * Objects that want to be notified of interaction between mouse
	 * and sprites have to implement the <code>GestureListener</code>
	 * interface.
	 *  
	 * @author	Cédric Néhémie
	 * @see		GestureManager
	 * @see		GestureEvent
	 */
	public interface GestureListener
	{
		/**
		 * Called when the user press the mouse's left button over a sprite.
		 *  
		 * @param e <code>GestureEvent</code> dispatched by the <code>GestureManager</code>
		 * 			object
		 */
		function onPress ( e : GestureEvent ) : void;
		/**
		 * Called when the user release the mouse's left button over a sprite.
		 *  
		 * @param e <code>GestureEvent</code> dispatched by the <code>GestureManager</code>
		 * 			object
		 */
		function onRelease ( e : GestureEvent ) : void;
		/**
		 * Called when the user release the mouse's left button outside
		 * of the sprite on which user press the mouse's left button.
		 *  
		 * @param e <code>GestureEvent</code> dispatched by the <code>GestureManager</code>
		 * 			object
		 */
		function onReleaseOutside ( e : GestureEvent ) : void;
		/**
		 * Called when the mouse cursor enters in a sprite according to the current 
		 * <code>GestureHitMode</code> object of the <code>GestureManager</code>.
		 *  
		 * @param e <code>GestureEvent</code> dispatched by the <code>GestureManager</code>
		 * 			object
		 */
		function onRollOver ( e : GestureEvent ) : void;
		/**
		 * Called when the mouse cursor leaves the sprite above which it was, 
	 	 * according to the current <code>GestureHitMode</code> object.
		 *  
		 * @param e <code>GestureEvent</code> dispatched by the <code>GestureManager</code>
		 * 			object
		 */
		function onRollOut ( e : GestureEvent ) : void;
		/**
		 * Called when the mouse cursor leave a sprite which have been previously
		 * pressed and not released yet.
		 *  
		 * @param e <code>GestureEvent</code> dispatched by the <code>GestureManager</code>
		 * 			object
		 */
		function onDragOver ( e : GestureEvent ) : void;
		/**
		 * Called when the mouse cursor enter a sprite which have previously trigger
		 * an <code>onDragOut</code> event.
		 * 
		 * @param e <code>GestureEvent</code> dispatched by the <code>GestureManager</code>
		 * 			object
		 */
		 function onDragOut ( e : GestureEvent ) : void;
	}
}